<?php

namespace app\model;

use think\Model;


class MemberBuyerCancelOrder extends Model
{
    protected $pk = 'orderid';

    public function getTypeAttr($value)
    {
        $status = [1 => '手动取消', 2 => '超时系统撤单'];
        return $status[$value];
    }

    public function order()
    {
        return $this->hasOne('Order', 'orderid', 'orderid');
    }

    public function task()
    {
        return $this->hasOne('Task', 'taskid', 'taskid');
    }
}